<?php

namespace app\mobileapp\validate;

use think\Validate;

class Member extends Validate
{
    protected $rule = [
        'username' => 'require',
        'sex' => 'require',
        'nickname' => 'require',
        'province' => 'require',
        'city' => 'require',
        'district' => 'require',
        'birthday' => 'require',
        'content_types' => 'require',
        'expect_object' => 'require',
        'wechat' => 'require',
        'wechat_hide' => 'require',
        'profession'=>'require',

    ];

    protected $message = [
        'username.require' => '手机号码不能为空',
        'sex.require' => '性别不能为空',
        'nickname.require' => '昵称不能为空',
        'province.require' => '省不能为空',
        'city.require' => '市不能为空',
        'district.require' => '区不能为空',
        'birthday.require' => '出生日期不能为空',
        'content_types.require' => '交友节目不能为空',
        'expect_object.require' => '期望对象不能为空',
        'wechat.require' => '微信不能为空',
        'wechat_hide.require' => '微信默认显示状态不能为空',
        'profession.require' => '职业不能为空',

    ];


    protected $scene = [
        'register' => ['username', 'sex', 'nickname', 'province', 'city', 'district', 'birthday', 'content_types', 'expect_object', 'wechat', 'wechat_hide'],
        'updateMember' => ['nickname', 'province', 'city', 'district', 'birthday', 'content_types', 'wechat', 'wechat_hide'],
    ];

}